Prizm Document Converter
Configure Express Samples

After the installation, test the sample application in a browser:

The demo.config file can be updated to customize the application host address, application port, and services port.

 
Copy Code
{
    "logging": {
        "consoleLogFilePath":
 "/usr/share/prizm/logs/CcsDemoService.console.log"
    },
    "httpService": {
        "port": 18001
    },
    "apiService": {
        "port": 18681,
        "host": "localhost"
    }
}

Express Sample Directory Structure

 
Copy Code
express
├── app
│   └── public
│       ├── app.css
│       ├── app.js
│       ├── conversionDataView
│       │   ├── conversionData.html
│       │   └── conversionData.module.js
│       ├── conversionView
│       │   ├── conversion.html
│       │   └── conversion.module.js
│       ├── downloadView
│       │   ├── download.html
│       │   └── download.module.js
│       ├── index.html
│       ├── requestCfgView
│       │   ├── requestCfg.html
│       │   └── requestCfg.module.js
│       ├── requestView
│       │   ├── request.html
│       │   └── request.module.js
│       └── uploadView
│           └── upload.module.js
├── app.js
├── demo.config
├── lib
│   └── config.js
├── node_modules
├── package.json
└── proxyFilter.js

File / Folder

Description

app.js

A node-js app that hosts the express app and proxy’s service requests.

proxyFilter.js

This filters the requests to the conversion service and white-lists headers to anf from the service.

package.json

The node-js package json file.

node_modules

The node-js npm dependencies.

lib/config.js

This object reads the configuration file used to define the application port and service host and port..

demo.config

A configuration file used to define the application port and service host and port.

public/app.js

This contains angular js app controller, main service and some helper directives.

public/app.css

The application CSS..

public/index.js

The entry point to the app and container for the child views.

public/uploadView/upload.module.js

The angular js controller for the upload functionality.

public/requestCfgView/requestCfg.html

The markup for the CCS request configuration view.

public/requestCfgView/requestCfg.module.js

The controller for the CCS request configuration view.

public/requestView/request.html

The markup for the request configuration.

public/requestView/request.module.js

The controller for the request configuration.

public/conversionView/conversion.html

The markup for the request button.

public/conversionView/conversion.module.js

The controller for the request button.

public/conversionDataView/conversionData.html

The markup for the conversion request/response view.

public/conversionDataView/conversionData.module.js

The controller for the conversion request/response view.

public/downloadView/download.html

The markup for the download view.

public/downloadView/download.module.js

The controller for the download view.

Starting and Stopping the Express Sample

The Express Sample is automatically started as part of the setup.sh script found in the installation directory, typically /usr/share/prizm/.  However, after rebooting, the Express sample will not be automatically restarted. To manually start and stop the Express sample, use the script found in /usr/share/prizm/scripts/demos.sh.

 

 


©2015. Accusoft Corporation. All Rights Reserved.

Send Feedback